package pers.cj.pdos.service;

import com.baomidou.mybatisplus.extension.service.IService;
import org.apache.ibatis.annotations.Param;
import pers.cj.pdos.entity.ArrearsWait;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;
import java.util.Map;

/**
 * <p>
 * 等待的收款，客户欠的款 服务类
 * </p>
 *
 * @author chenj
 * @since 2020-03-05
 */
public interface IArrearsWaitService extends IService<ArrearsWait> {

    List<Map> listVo(String companyId,
                     Integer page,
                     Integer limit,
                     String storeId,
                     String customTypeId,
                     Boolean notNeedIn,
                     Boolean customNoStop,
                     String search);

    long count(String companyId,
               String storeId,
               String customTypeId,
               Boolean notNeedIn,
               Boolean customNoStop,
               String search);

    Map getMapByCustom(String customId);

    List<Map> listDetail(String customId,
                         Integer page,
                         Integer limit,
                         Boolean close,
                         String search,
                         String no,
                         String remark,
                         String userId,
                         Date date1,
                         Date date2,
                         Integer flag,
                         String storeId);


    long countDetail(String customId,
                     Boolean close,
                     String search,
                     String no,
                     String remark,
                     String userId,
                     Date date1,
                     Date date2,
                     Integer flag,
                     String storeId);

    /**
     * 获取总应收款
     * @param companyId
     * @return
     */
    BigDecimal getTotalAmount(String companyId);
}
